<!-- xml version="1.0" encoding="utf-8" -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
	<title>De Bello Gallico</title>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
	<link href="../flashcard.css" rel="stylesheet" type="text/css">
</head>


<script type="text/javascript">
var sentences = [
  [ ["Apud", "Helvetios", "longe", "nobilissimus", "fuit", "et", "ditissimus", "Orgetorix."],
    ["Among", "Helvetii", "far", "most-noble", "was", "and", "most-rich", "Orgetorix."] ],
  [ ["Is", "M.", "Messalla", "et", "M.", "Pisone", "consulibus", "regni", "cupiditate", "inductus"],
    ["That-one", "Marcus", "Messala", "and", "Marcus", "Piso", "[being]_consuls,", "of-royal-power", "by-[the]-desire", "induced,"] ],
  [ ["coniurationem", "nobilitatis", "fecit", "et", "civitati", "persuasit,"],
    ["conspiracy", "of-[the]-nobility", "made", "and", "on-[the]-state", "prevailed,"] ],
  [ ["ut", "de", "finibus", "suis", "cum", "omnibus", "copiis", "exirent:"],
    ["that", "from", "territories", "their-own", "with", "all", "forces", "out-they-should-go:"] ],
  [ ["perfacile", "esse,", "cum", "virtute", "omnibus", "praestarent,", "totius", "Galliae", "imperio", "potiri."],
    ["very-easy", "to-be,", "since", "in-valor", "all", "before-they-stand,", "of-all", "Gaul", "[the]-empire", "to-get-possession-of."] ],
  [ ["Id", "hoc", "facilius", "eis", "persuasit,", "quod", "undique", "loci", "natura", "Helvetii", "continentur:"],
    ["That-thing", "by-reason-of-this", "[the]-more-easily", "on-them", "he-gained-by-urging,", "because", "from-all-sides", "of-the-locality", "by-the-nature", "Helvetii", "together-are-held:"] ],
  [ ["una", "ex", "parte", "flumine", "Rheno", "latissimo", "atque", "altissimo,", "qui", "agrum", "Helvetium", "a", "Germanis", "dividit;"],
    ["one", "from", "side", "by-river", "Rhine", "very-wide", "and", "very-deep,", "which", "country", "Helvetian", "from", "Germans", "divides;"] ],
  [ ["altera", "ex", "parte", "monte", "Iura", "altissimo,", "qui", "est", "inter", "Sequanos", "et", "Helvetios;"],
    ["other", "from", "side", "by-[the]-mountain", "Jura", "very-high,", "which", "is", "between", "Sequani", "and", "Helvetii;"] ],
  [ ["tertia", "lacu", "Lemanno", "et", "flumine", "Rhodano,", "qui", "provinciam", "nostram", "ab", "Helvetiis", "dividit."],
    ["from-third", "by-lake", "Leman", "and", "river", "Rhone,", "which", "province", "our", "from", "Helvetii", "divides."] ],
  [ ["His", "rebus", "fiebat", "ut", "et", "minus", "late", "vagarentur", "et", "minus", "facile", "finitimis", "bellum", "inferre", "possent;"],
    ["From-these", "things", "it-happened", "that", "both", "less", "widely", "they-could-range", "and", "less", "easily", "against-neighbors", "war", "on-carry", "could;"] ],
  [ ["qua", "ex", "parte", "homines", "bellandi", "cupidi", "magno", "dolore", "adficiebantur."],
    ["which", "from", "account", "[being]_men", "of-fighting", "desirous", "with-great", "grief", "they-were-being-affected."] ],
  [ ["Pro", "multitudine", "autem", "hominum", "et", "pro", "gloria", "belli", "atque", "fortitudinis", "angustos", "se", "fines", "habere", "arbitrabantur,"],
    ["In-proportion-to", "[the]-multitude", "moreover", "of-men", "and", "for", "glory", "of-war", "and-also", "of-bravery", "narrow", "themselves", "boundaries", "to-have", "they-were-wont-to-think,"] ],
  [ ["qui", "in", "longitudinem", "milia", "passuum", "CCXL,", "in", "latitudinem", "CLXXX", "patebant."],
    ["which", "in", "length", "thousands", "of-paces", "two-hundred_and_forty,", "in", "breadth", "one-hundred_and_eighty", "lay-open."] ]
];

var i = 0;
var j = 0;

var shown = 0;

function updateVoc() {
	
	var sentence = "";
	
	for(n = 0; n < sentences[i][0].length; n++) {
		if (n == j) {
			sentence += ' <span class="curword">' + sentences[i][0][n] + "</span>";
		} else {
			sentence += " " + sentences[i][0][n];
		}
	}
	
	document.getElementById('v3').innerHTML = sentence;
	
	if (shown == 0) {
		document.getElementById('v1').innerHTML = "";
	} else {
		document.getElementById('v1').innerHTML = sentences[i][1][j];
	}
}

function next() {
	shown++;
	if (shown > 1) {
		shown = 0;
		j++;
		if (j >= sentences[i][0].length) {
			j = 0;
			i++;
			if (i >= sentences.length) {
				i = 0;
				alert('All done!');
			}
		}
	}
	updateVoc();
}

function prev() {
	shown--;
	if (shown < 0) {
		shown = 1;
		j--;
		
		if (j < 0) {
			i--;
			if (i < 0) {
				i = sentences.length - 1;
				alert('All done!');
			}
			j = sentences[i][0].length - 1;
		}
	}
	
	updateVoc();
}

</script>

<body onload="updateVoc()">
<h1 style="text-align:center; color: #60B0C0;">Liber I - Caput II</h1>

<div class="center">
<div id="v3" class="v3"></div>
<div id="v2" class="v2">&nbsp;</div>
<div id="v1" class="v1"></div>


<a href="#" class="button" id="btnprev" onclick="prev()" accesskey="p">&lt;&lt;</a>
<a href="#" class="button" id="btnnext" onclick="next()" accesskey="n">&gt;&gt;</a>


</div>
</body>
</html>
